package com.mzy.datepackage.M2022.Feb.Eight;

/**
 * Created with IntelliJ IDEA.
 *
 * @Author mzy
 * @Date 2022/2/8 20:44
 * @Version 1.0
 */
public class Father {
    private String name="小明";
    private static Integer age=10;


    {
        System.out.println("父类：" +this.name);
        this.name="小黄";
        System.out.println("父类：" +this.name);
    }

    static {

        System.out.println("父类静态代码块");
        System.out.println("父类静态成员：" + age);
    }

    public Father(String name) {
        this.name = name;

    }

    public Father() {
        System.out.println("父类构造器");
    }

}
